<!DOCTYPE html>
<html lang="en" style="height:100%">

<head>
	<meta charset="UTF-8">
	<meta name="viewport"
		content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
	<meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
	<title>我的资产</title>
	<link rel="stylesheet" type="text/css" href="../../css/api.css" />
	<link rel="stylesheet" type="text/css" href="../../css/style.css" />
	<link rel="stylesheet" type="text/css" href="../../css/yzl.css" />
	<!-- <link rel="stylesheet" href="../../css/sqc.css"> -->
	<style>
	*{
		margin: 0;
		padding: 0;
	}
	input{
		outline:none;
	}
	</style>
</head>

<body style="background: #f7f4f2;">
<div id="blank" class="header" v-cloak>
	<div v-back.tapmode class="back"></div>
	<div class="title">我的资产</div>
</div>
<div id="app" v-cloak style="padding-top:60px;">
	<div class="people-number assets" style="margin-bottom: 12px">
		<div class="total-value">
			<div class="character-number-one" style="margin:20px 0 10px 0;font-weight: bold;">
				<div>{{detailed_list.balance.toFixed(2)}}</div>
			</div>
			<div class="character-number-one" style="font-size:12px;">
				<div>钻石(QHR)余额</div>
			</div>
			<div class="transaction">
				<div v-myclick="give">
					转赠给他人
				</div>
			</div>
		</div>
		<div class="income">
			<div class="income-title">
				<div class="income-number">{{detailed_list.inMasonry}}</div>
				<div class="income-number">{{detailed_list.outMasonry}}</div>
			</div>
			<div style="">
				<div class="income-number">收入</div>
				<div class="income-number">支出</div>
			</div>
		</div>
	</div>

	<div class="invite" style="margin-top:0px;">
		<div class="invite-detailed">明细</div>
		<div>
			<div class="invite-people record" v-for="(list,index) in detailed_list.masonrylist" style="position:relative;">
				<div style="margin-bottom:9px;">
					<span style="font-size:15px;">{{itemtype[list.type]}}</span>
				</div>
				<div style="float:left;">
					<span class="people-news" style="margin-left:0px;color:#F95656">{{list.createTime}}</span>
					<!--<span class="people-news"><a style="color:#F95656">{{list.createTime}}</a></span>-->
				</div>
				<div class="number-reward" style="width: auto;">
					{{list.symbolType == 1 ? '+' : '-'}}<span>{{(list.masonryNum).toFixed(2)}}</span>
				</div>
			</div>
		</div>
	</div>
	<div style="text-align:center;margin-top:50px" v-show="detailed_list.masonrylist == ''">
		<img src="../../image/big/1-qiaobao.png" style="margin:0 auto;width:25%">
		<div style="margin:0 auto;color:#999999;text-align:center;padding-top:20px;font-size:12px">你的交易明细将会显示在这里</div>
	</div>
</div>
</body>
<script src="../../script/api.js"></script>
<script src="../../script/vue.js"></script>
<script src="../../script/app.js"></script>
<script src="../../script/common.js"></script>
<script src="../../script/url.js"></script>
<script src="../../script/components.js"></script>
<script type="text/javascript" src="../../script/jquery.js"></script>

<script>
	var vm,
		wx,
		detailed_list,
	apiready = function () {
		setBSImg();
		new Vue({
			el: '#blank'
		})
		wx = api.require('wx');
		// setBSImg();
		showProgress();
		var data = {
			wxOpenId:getPrefs('openid'),
			token:getPrefs('token'),
		};
		var callback=function(ret){
			detailed_list = ret.content;
			console.log(JSON.stringify(detailed_list));
			initApp();
		}
		pinet.post(APIURLP+'/play/user/myMasonry',data, callback);
		api.parseTapmode();
	};

	function initApp() {
		// var isBigImg = Vue.BSImg == 'big';
		vm = new Vue({
			el: '#app',
			data: {
				itemtype: {
					'1': '完成任务',
					'2': '活力值奖励 ',
					'3': '赠送给Ta',
					'4': 'Ta人赠送',
					'5': '转出手续费',
					'6': '转入手续费',
					'7': '交易所转入',
					'8': '转出砖石',
					'9': '购买任务消耗',
					'10': '赠送礼物手续费',
					'11': '实名制获取奖励 ',
					'12': '活力值增加',
					'13': '活力值到期',
					'14': '平台等级分红1级',
					'15': '平台等级分红2级',
					'16': '平台等级分红3级',
					'17': '平台等级分红4级',
					'18': '平台等级分红5级',
				},
				detailed_list:detailed_list,
			},
			computed: {

			},
			methods: {
				cash:function(){
					api.openWin({
						name: 'exchange',
						url: './exchange.html'
					})
				},
				give:function(){
					api.openWin({
					    name: 'sendingdiamonds',
					    url: './sendingdiamonds.html'
					});
				},
			},
			watch: {

			},
		})
	}


</script>

</html>
